<!DOCTYPE html>
<html lang="en">

	<head>
		<meta charset="UTF-8">
		<meta name="renderer" content="webkit">
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
		<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
		<title>建新街道移动办公 - E事通</title>
		<link rel="stylesheet" href="/app/static/layui/css/layui.css">
		<link rel="stylesheet" href="/app/static/styles/style.css">
		<link rel="icon" href="image/code.png">
		<script src="/app/static/scripts/jquery-1.9.1.js"></script>
		<script type="text/javascript" src="/app/static//layui/layui.all.js"></script>
		<script type="text/javascript" src="/app/static/scripts/index.js"></script>
		<style type="text/css">
			.sort_mark{
				
			}
		</style>
	</head>

	<body class="body">

		<div class="section">
			<div class="wrapper-md">
				<h1 class="fl" id="title">积分管理</h1>
				<div class="fr">
					<div class="def-btn-group">
						<button class="def-btn def-btn-primary" onclick="window.location.href='add.html'"><i class="gopng gopng_page"></i> 添加</button>
					</div>
				</div>
			</div>

			<div class="section-content">
				<div class="layui-form filterDiv">
					<div class="layui-inline">
						<label for="">社工名称：</label>
						<div class="layui-input-inline">
							<input type="text" class="layui-input" />
						</div>
					</div>
					<div class="layui-inline">
						<label for="">储蓄所名称：</label>
						<div class="layui-input-inline">
							<select>
								<option value="0">全部</option>
								<option value="1">交通运输部</option>
								<option value="2">厅机关</option>
								<option value="3">厅直单位</option>
								<option value="4">地市交通局</option>
							</select>
						</div>
					</div>
					<div class="layui-inline">
						<label for="">账号：</label>
						<div class="layui-input-inline">
							<input type="text" class="layui-input" />
						</div>
					</div>
					<button class="def-btn def-btn-normal ml20"><i class="gopng gopng_search"></i> 查询</button>
				</div>
				<div class="layui-form">
					<table class="layui-table table-center table-blue">
						<colgroup>
							<col width="50" />
						</colgroup>
						<thead>
							<tr>
								<th><input type="checkbox" name="" lay-skin="primary" lay-filter="allChoose"></th>
								<th>社工姓名</th>
								<th>账号</th>
								<th style="position: relative;">积分合计
									<span class="layui-table-sort layui-inline" lay-sort="desc">
										<i class="layui-edge layui-table-sort-asc"></i>
										<i class="layui-edge layui-table-sort-desc"></i>
									</span>
								</th>
								<th>储蓄所名称</th>
								<th>操作</th>
							</tr>
						</thead>
						<tbody>
							<tr>
								<td><input type="checkbox" name="" lay-skin="primary"></td>
								<td>张某</td>
								<td>HPXC-D-10103</td>
								<td>17</td>
								<td>和平新村社区</td>
								<td>
									<div id="tableHandleBtn" class="def-breadcrumb">
										<span class="detial" onclick="window.location.href='detial.html'">查看</span>
										<span class="edit" onclick="window.location.href='edit.html'">编辑</span>
										<span class="add" onclick="add()">添加</span>
										<span class="exec" onclick="exec()">兑换</span>
									</div>
								</td>
							</tr>
							<tr>
								<td><input type="checkbox" name="" lay-skin="primary"></td>
								<td>王某</td>
								<td>HPXC-D-10103</td>
								<td>23</td>
								<td>和平新村社区</td>
								<td>
									<div id="tableHandleBtn" class="def-breadcrumb">
										<span class="detial" onclick="window.location.href='detial.html'">查看</span>
										<span class="edit" onclick="window.location.href='edit.html'">编辑</span>
										<span class="add" onclick="add()">添加</span>
										<span class="exec" onclick="exec()">兑换</span>
									</div>
								</td>
							</tr>
							<tr>
								<td><input type="checkbox" name="" lay-skin="primary"></td>
								<td>李娜</td>
								<td>HPXC-D-10103</td>
								<td>45</td>
								<td>花园路社区</td>
								<td>
									<div id="tableHandleBtn" class="def-breadcrumb">
										<span class="detial" onclick="window.location.href='detial.html'">查看</span>
										<span class="edit" onclick="window.location.href='edit.html'">编辑</span>
										<span class="add" onclick="add()">添加</span>
										<span class="exec" onclick="exec()">兑换</span>
									</div>
								</td>
							</tr>
							<tr>
								<td><input type="checkbox" name="" lay-skin="primary"></td>
								<td>小屋</td>
								<td>HPXC-D-10103</td>
								<td>22</td>
								<td>历山东路社区</td>
								<td>
									<div id="tableHandleBtn" class="def-breadcrumb">
										<span class="detial" onclick="window.location.href='detial.html'">查看</span>
										<span class="edit" onclick="window.location.href='edit.html'">编辑</span>
										<span class="add" onclick="add()">添加</span>
										<span class="exec" onclick="exec()">兑换</span>
									</div>
								</td>
							</tr>
						</tbody>
					</table>

					<div class="text-right">
						<div id="page"></div>
					</div>
				</div>
			</div>
		</div>

		<!--新增弹框-->
		<script type="text/template" id="addNew_modal">
			<div class="modal_content modal_label_width">
				<form class="layui-form">
					<div class="layui-form-item">
						<label class="layui-form-label">服务内容</label>
						<div class="layui-input-block">
							<input type="text" lay-verify="required" class="layui-input">
						</div>
					</div>
					<div class="layui-form-item">
						<label class="layui-form-label">服务时间</label>
						<div class="layui-input-block">
							<input type="text" class="layuiTime layui-input" lay-verify="required">
						</div>
					</div>
					<div class="layui-form-item">
						<label class="layui-form-label">可获积分</label>
						<div class="layui-input-block">
							<input type="text" lay-verify="required" class="layui-input">
						</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-input-block">
							<button class="layui-btn" id="ss" lay-submit lay-filter="formDemo">立即提交</button>
						</div>
					</div>
				</form>
			</div>
		</script>
		<!--/ 新增弹框-->

		<!--兑换弹框-->
		<script type="text/template" id="edit_modal">
			<div class="modal_content modal_label_width">
				<form class="layui-form">
					<div class="layui-form-item">
						<label class="layui-form-label">兑换内容</label>
						<div class="layui-input-block">
							<select name="">
								<option value="0">兑换物品</option>
								<option value="1">兑换服务</option>
							</select>
						</div>
					</div>
					<div class="layui-form-item">
						<label class="layui-form-label">兑换积分</label>
						<div class="layui-input-block">
							<input type="text" lay-verify="required" class="layui-input">
						</div>
					</div>
					<div class="layui-form-item">
						<label class="layui-form-label">兑换时间</label>
						<div class="layui-input-block">
							<input type="text" lay-verify="required" class="layui-input layuiTime">
						</div>
					</div>
				</form>
			</div>
		</script>
		<!--/ 兑换弹框-->

		<script type="text/javascript">
			var form = layui.form,
				layer = layui.layer,
				layedit = layui.layedit,
				laypage = layui.laypage,
				laydate = layui.laydate;

			form.render();

			//查看
			function detial() {

			}
			//编辑
			function edit() {

			}
			//添加
			function add() {
				layui.layer.open({
					type: 1,
					skin: 'layui-layer-demo', //样式类名
					anim: 2,
					title: '添加',
					closeBtn: 1, //不显示关闭按钮
					shadeClose: false, //开启遮罩关闭
					area: ['500px', '350px'],
					btn: ['确定'],
					yes: function(index, layero) { //按钮【按钮一】的回调
						alert('点击了确定')
						//$(layero).find('form').submit()

						//layer.close(index)		//关闭方法
						layero.find('#ss').click();
					},
					content: $('#addNew_modal').html(),
					success: function() {
						form.render();
						laydate.render({
							elem: '.layuiTime' //指定元素
						});
						form.on('submit(formDemo)', function(data) {
							layer.msg(JSON.stringify(data.field));
							return false;
						});
					}
				})
			}
			//兑换
			function exec() {
				layui.layer.open({
					type: 1,
					skin: 'layui-layer-demo', //样式类名
					anim: 2,
					title: '兑换',
					closeBtn: 1, //不显示关闭按钮
					shadeClose: false, //开启遮罩关闭
					area: ['500px', '350px'],
					btn: ['确定'],
					yes: function(index, layero) { //按钮【按钮一】的回调
						alert('点击了确定')
						layer.close(index) //关闭方法
					},
					content: $('#edit_modal').html(),
					success: function() {
						form.render();
						laydate.render({
							elem: '.layuiTime' //指定元素
						});
					}
				})
			}

			//分页
			laypage.render({
				elem: 'page' //注意，这里的 test1 是 ID，不用加 # 号
					,
				count: 50 //数据总数，从服务端得到
					,
				skin: '#1E9FFF',
				skip: true
			});
		</script>

	</body>

</html>